home *** CD-ROM | disk | FTP | other *** search
/ Language/OS - Multiplatform Resource Library / LANGUAGE OS.iso / cpp_libs / sos3-2.lha / include / dir_use.h < prev    next >
C/C++ Source or Header  |  1991-11-08  |  9KB  |  213 lines

  1. #ifndef dir_SOSH
  2. #define dir_SOSH 1
  3.  
  4. #include "knl_use.h"
  5. #include "agg_use.h"
  6. class sos_String_sos_Object_Association;
  7. class sos_String_sos_Object_Mapping;
  8. class sos_Object_Directory;
  9. typedef class sos_Object_Directory sos_Directory;
  10. class sos_String_sos_Object_Association: public sos_Root_class 
  11. {  friend class _sos_Object_sos_Object_Association;
  12.    class _sos_Object_sos_Object_Association* _ref;
  13. public:
  14.    operator sos_Object ();
  15.    operator sos_Aggregate ();
  16.    operator sos_Object_sos_Object_Association ();
  17.    static sos_String_sos_Object_Association make(sos_Typed_id&);
  18.    static sos_String_sos_Object_Association make(sos_Typed_id&p,_sos_Object_sos_Object_Association*r){
  19.    sos_String_sos_Object_Association o; o._tpid = p; o._ref=r; return o;}
  20.    static sos_String_sos_Object_Association make(sos_Root_class&);
  21.    sos_Offset _size();
  22.    static sos_String_sos_Object_Association create(sos_Container,sos_Bool role1_based_on_equal = FALSE,sos_Bool role2_based_on_equal = FALSE);
  23.    static sos_String_sos_Object_Association copy(sos_String_sos_Object_Association,sos_Container);
  24.    static sos_String_sos_Object_Association clone(sos_String_sos_Object_Association,sos_Container);
  25.    void destroy();
  26.    sos_Int hash_value();
  27.    sos_Bool is_role2(sos_Object _p1);
  28.    sos_String get_role1(sos_Cursor _p1);
  29.    sos_Object get_role2(sos_Cursor _p1);
  30.    sos_Bool is_empty();
  31.    sos_Int card();
  32.    sos_Cursor open_cursor(sos_Container _p1 = TEMP_CONTAINER);
  33.    void close_cursor(sos_Cursor _p1);
  34.    sos_Cursor duplicate(sos_Cursor _p1);
  35.    sos_Bool is_valid(sos_Cursor _p1);
  36.    void remove_at(sos_Cursor _p1);
  37.    sos_Bool to_first(sos_Cursor _p1);
  38.    sos_Bool to_last(sos_Cursor _p1);
  39.    sos_Bool to_pred(sos_Cursor _p1,sos_Int _p2 = 1);
  40.    sos_Bool has_type(sos_Type _p1);
  41.    sos_Bool isa(sos_Type _p1);
  42.    sos_Bool operator==(sos_Object _p1);
  43.    sos_Bool operator!=(sos_Object _p1);
  44.    void assign(sos_Object source);
  45.    sos_Bool equal(sos_Object o,sos_Eq_kind eq_kind = EQ_STRONG);
  46.    sos_Bool is_role1(sos_String _p1);
  47.    void clear();
  48.    sos_Bool to_succ(sos_Cursor _p1,sos_Int _p2 = 1);
  49.    sos_Type type();
  50.    sos_Bool is_some(sos_Type _p1);
  51.    sos_Bool is_value();
  52.    sos_Int size();
  53.    sos_Bool identical(sos_Object _p1);
  54.    sos_Bool like(sos_Object _p1);
  55.    sos_Comp_result compare_ids(sos_Object _p1);
  56. };
  57. #define _sos_String_sos_Object_Association_type sos_Id::make(sos_Container::make(7053596),3392)
  58. #define sos_String_sos_Object_Association_type sos_type_object(_sos_String_sos_Object_Association_type,sos_Id::make(sos_Container::make(279048),529560))
  59. class sos_String_sos_Object_Mapping: public sos_Root_class 
  60. {  friend class _sos_Object_sos_Object_Mapping;
  61.    class _sos_Object_sos_Object_Mapping* _ref;
  62. public:
  63.    operator sos_Object ();
  64.    operator sos_Aggregate ();
  65.    operator sos_String_sos_Object_Association ();
  66.    operator sos_Object_sos_Object_Association ();
  67.    operator sos_Object_sos_Object_Mapping ();
  68.    static sos_String_sos_Object_Mapping make(sos_Typed_id&);
  69.    static sos_String_sos_Object_Mapping make(sos_Typed_id&p,_sos_Object_sos_Object_Mapping*r){
  70.    sos_String_sos_Object_Mapping o; o._tpid = p; o._ref=r; return o;}
  71.    static sos_String_sos_Object_Mapping make(sos_Root_class&);
  72.    sos_Offset _size();
  73.    static sos_String_sos_Object_Mapping create(sos_Container,sos_Bool list_cursor = FALSE,sos_Bool key_based_on_equal = FALSE,sos_Bool info_based_on_equal = FALSE);
  74.    static sos_String_sos_Object_Mapping copy(sos_String_sos_Object_Mapping,sos_Container);
  75.    static sos_String_sos_Object_Mapping clone(sos_String_sos_Object_Mapping,sos_Container);
  76.    void destroy();
  77.    sos_Int hash_value();
  78.    sos_Object operator[](sos_String _p1);
  79.    sos_Object get_info(sos_Cursor _p1);
  80.    void set_info(sos_Cursor _p1,sos_Object _p2);
  81.    sos_Bool is_role2(sos_Object _p1);
  82.    sos_Int card();
  83.    sos_Cursor open_cursor(sos_Container _p1 = TEMP_CONTAINER);
  84.    void close_cursor(sos_Cursor _p1);
  85.    sos_Cursor duplicate(sos_Cursor _p1);
  86.    sos_Bool to_last(sos_Cursor _p1);
  87.    sos_Bool to_pred(sos_Cursor _p1,sos_Int _p2 = 1);
  88.    sos_Bool is_empty();
  89.    sos_Bool isa(sos_Type _p1);
  90.    sos_Bool operator==(sos_Object _p1);
  91.    sos_Bool operator!=(sos_Object _p1);
  92.    void assign(sos_Object source);
  93.    sos_Bool equal(sos_Object o,sos_Eq_kind eq_kind = EQ_STRONG);
  94.    sos_Bool is_info(sos_Object _p1);
  95.    void clear();
  96.    void insert_after(sos_Cursor _p1,sos_String _p2,sos_Object _p3);
  97.    sos_String get_role1(sos_Cursor _p1);
  98.    sos_Object get_role2(sos_Cursor _p1);
  99.    void remove_at(sos_Cursor _p1);
  100.    sos_Bool is_valid(sos_Cursor _p1);
  101.    sos_Bool to_first(sos_Cursor _p1);
  102.    sos_Bool has_type(sos_Type _p1);
  103.    sos_Bool is_key(sos_String _p1);
  104.    void remove(sos_String _p1);
  105.    sos_String get_key(sos_Cursor _p1);
  106.    void move_cursor(sos_Cursor _p1,sos_String _p2);
  107.    sos_Bool is_role1(sos_String _p1);
  108.    sos_Bool to_succ(sos_Cursor _p1,sos_Int _p2 = 1);
  109.    sos_Bool is_some(sos_Type _p1);
  110.    sos_Bool is_value();
  111.    sos_Bool identical(sos_Object _p1);
  112.    sos_Comp_result compare_ids(sos_Object _p1);
  113.    void insert(sos_String _p1,sos_Object _p2);
  114.    void insert_before(sos_Cursor _p1,sos_String _p2,sos_Object _p3);
  115.    sos_Int size();
  116.    sos_Type type();
  117.    sos_Bool like(sos_Object _p1);
  118. };
  119. #define _sos_String_sos_Object_Mapping_type sos_Id::make(sos_Container::make(7053596),3072)
  120. #define sos_String_sos_Object_Mapping_type sos_type_object(_sos_String_sos_Object_Mapping_type,sos_Id::make(sos_Container::make(279048),529560))
  121. class sos_Object_Directory: public sos_Root_class 
  122. {  friend class _sos_Object_Directory;
  123.    class _sos_Object_Directory* _ref;
  124. public:
  125.    operator sos_Object ();
  126.    operator sos_Aggregate ();
  127.    operator sos_String_sos_Object_Association ();
  128.    operator sos_Object_sos_Object_Association ();
  129.    operator sos_String_sos_Object_Mapping ();
  130.    operator sos_Object_sos_Object_Mapping ();
  131.    operator sos_Named ();
  132.    static sos_Object_Directory make(sos_Typed_id&);
  133.    static sos_Object_Directory make(sos_Typed_id&p,_sos_Object_Directory*r){
  134.    sos_Object_Directory o; o._tpid = p; o._ref=r; return o;}
  135.    static sos_Object_Directory make(sos_Root_class&);
  136.    sos_Offset _size();
  137.    static sos_Object_Directory create(sos_Container,sos_String name);
  138.    static sos_Object_Directory copy(sos_Object_Directory,sos_Container);
  139.    static sos_Object_Directory clone(sos_Object_Directory,sos_Container);
  140.    void destroy();
  141.    sos_Int hash_value();
  142.    static sos_Object_Directory root();
  143.    sos_Object operator[](sos_String _p1);
  144.    sos_Object get_info(sos_Cursor _p1);
  145.    void set_info(sos_Cursor _p1,sos_Object _p2);
  146.    sos_Bool is_role2(sos_Object _p1);
  147.    sos_Int card();
  148.    sos_Cursor open_cursor(sos_Container _p1 = TEMP_CONTAINER);
  149.    void close_cursor(sos_Cursor _p1);
  150.    sos_Cursor duplicate(sos_Cursor _p1);
  151.    sos_Bool to_last(sos_Cursor _p1);
  152.    sos_Bool to_pred(sos_Cursor _p1,sos_Int _p2 = 1);
  153.    sos_Bool is_empty();
  154.    sos_Bool isa(sos_Type _p1);
  155.    sos_Bool operator==(sos_Object _p1);
  156.    sos_Bool operator!=(sos_Object _p1);
  157. protected:
  158.    static void local_assign(sos_Object_Directory x,sos_Object_Directory y);
  159.    static sos_Bool local_equal(sos_Object_Directory x,sos_Object_Directory y,sos_Eq_kind eq_kind = EQ_STRONG);
  160. public:
  161.    void assign(sos_Object source);
  162.    sos_Bool equal(sos_Object o,sos_Eq_kind eq_kind = EQ_STRONG);
  163.    void insert(sos_String _p1,sos_Object _p2);
  164. protected:
  165.    static void local_finalize(sos_Object_Directory _p1);
  166. public:
  167.    sos_Bool is_info(sos_Object _p1);
  168.    void clear();
  169.    void insert_before(sos_Cursor _p1,sos_String _p2,sos_Object _p3);
  170.    sos_Int size();
  171. protected:
  172.    sos_Bool get_role1_based_on_equal();
  173.    void set_role1_based_on_equal(sos_Bool _p1);
  174.    sos_Bool get_role2_based_on_equal();
  175.    void set_role2_based_on_equal(sos_Bool _p1);
  176. public:
  177.    sos_Type type();
  178.    sos_Bool like(sos_Object _p1);
  179.    sos_String get_name();
  180.    void set_name(sos_String _p1);
  181.    static void set_wd_from_env();
  182.    void insert_after(sos_Cursor _p1,sos_String _p2,sos_Object _p3);
  183.    sos_String get_role1(sos_Cursor _p1);
  184.    sos_Object get_role2(sos_Cursor _p1);
  185.    void remove_at(sos_Cursor _p1);
  186.    sos_Bool is_valid(sos_Cursor _p1);
  187.    sos_Bool to_first(sos_Cursor _p1);
  188.    sos_Bool has_type(sos_Type _p1);
  189.    void remove(sos_String _p1);
  190.    static sos_Object lookup(sos_String _p1);
  191.    static void set_wd(sos_String _p1);
  192.    static sos_Object_Directory get_wd();
  193. protected:
  194.    static void local_initialize(sos_Object_Directory _p1);
  195. public:
  196.    sos_Bool is_key(sos_String _p1);
  197.    sos_String get_key(sos_Cursor _p1);
  198.    void move_cursor(sos_Cursor _p1,sos_String _p2);
  199.    sos_Bool is_role1(sos_String _p1);
  200.    sos_Bool to_succ(sos_Cursor _p1,sos_Int _p2 = 1);
  201.    sos_Bool is_some(sos_Type _p1);
  202.    sos_Bool is_value();
  203.    sos_Bool identical(sos_Object _p1);
  204.    sos_Comp_result compare_ids(sos_Object _p1);
  205. protected:
  206.    static sos_Int local_hash_value(sos_Object_Directory x);
  207. };
  208. #define _sos_Object_Directory_type sos_Id::make(sos_Container::make(7053596),1288)
  209. #define sos_Object_Directory_type sos_type_object(_sos_Object_Directory_type,sos_Id::make(sos_Container::make(279048),529560))
  210. #define _sos_Directory_type sos_Id::make(sos_Container::make(7053596),1288)
  211. #define sos_Directory_type sos_type_object(_sos_Directory_type,sos_Id::make(sos_Container::make(279048),529560))
  212. #endif
  213.